<?php
/**
 * Created by PhpStorm.
 * User: 26243
 * Date: 2017/5/6
 * Time: 19:20
 */
header('Content-Type: application/json');
require_once '../include.php';
$id = $_REQUEST['id'];
$proInfo = getProById($id);
$proImgs = getProImgsById($id);
if (!($proImgs && is_array($proImgs))){
    alertMes("商品图片错误!", "index.php");
}
//var_dump($proInfo);
session_start();
$userid = $_SESSION['loginFlag'];
?>
<!DOCTYPE html>
<!--[if IE 9]> <html lang="en" class="ie9"> <![endif]-->
<!--[if !IE]><!-->
<html lang="en">
<!--<![endif]-->
	<head>
		<meta charset="utf-8">
		<title>Product</title>
		<meta name="description" content="iDea a Bootstrap-based, Responsive HTML5 Template">
		<meta name="author" content="htmlcoder.me">

		<!-- Mobile Meta -->
		<meta name="viewport" content="width=device-width, initial-scale=1.0">

		<!-- Favicon -->
		<link rel="shortcut icon" href="images/favicon.ico">

		<!-- Web Fonts -->



		<!-- Bootstrap core CSS -->
		<link href="bootstrap/css/bootstrap.css" rel="stylesheet">

		<!-- Font Awesome CSS -->
		<link href="fonts/font-awesome/css/font-awesome.css" rel="stylesheet">

		<!-- Fontello CSS -->
		<link href="fonts/fontello/css/fontello.css" rel="stylesheet">

		<!-- Plugins -->
		<link href="plugins/magnific-popup/magnific-popup.css" rel="stylesheet">
		<link href="css/animations.css" rel="stylesheet">
		<link href="plugins/owl-carousel/owl.carousel.css" rel="stylesheet">

		<!-- iDea core CSS file -->
		<link href="css/style.css" rel="stylesheet">

		<!-- Color Scheme (In order to change the color scheme, replace the red.css with the color scheme that you prefer)-->
		<link href="css/skins/red.css" rel="stylesheet">

		<!-- Custom css -->
		<link href="css/custom.css" rel="stylesheet">
	</head>

	<!-- body classes:
			"boxed": boxed layout mode e.g. <body class="boxed">
"pattern-1 ... pattern-9": background patterns for boxed layout mode e.g. <body class="boxed pattern-1">
-->
	<body>
		<!-- scrollToTop -->
		<!-- ================ -->
		<div class="scrollToTop"><i class="icon-up-open-big"></i></div>

		<!-- page wrapper start -->
		<!-- ================ -->
		<div class="page-wrapper">

            <!-- header-top start -->
            <!-- ================ -->
            <div class="header-top">
                <div class="container">
                    <div class="row">
                        <div class="col-xs-2 col-sm-6">

                            <!-- header-top-first start -->
                            <!-- ================ -->
                            <div class="header-top-first clearfix">
                                <ul class="social-links clearfix hidden-xs">
                                    <li class="twitter"><a target="_blank" href=""><i class="fa fa-twitter"></i></a></li>
                                    <li class="skype"><a target="_blank" href=""><i class="fa fa-skype"></i></a></li>
                                    <li class="linkedin"><a target="_blank" href=""><i class="fa fa-linkedin"></i></a></li>
                                    <li class="googleplus"><a target="_blank" href=""><i class="fa fa-google-plus"></i></a></li>
                                    <li class="youtube"><a target="_blank" href=""><i class="fa fa-youtube-play"></i></a></li>
                                    <li class="flickr"><a target="_blank" href=""><i class="fa fa-flickr"></i></a></li>
                                    <li class="facebook"><a target="_blank" href=""><i class="fa fa-facebook"></i></a></li>
                                    <li class="pinterest"><a target="_blank" href=""><i class="fa fa-pinterest"></i></a></li>
                                </ul>
                                <div class="social-links hidden-lg hidden-md hidden-sm">
                                    <div class="btn-group dropdown">
                                        <button type="button" class="btn dropdown-toggle" data-toggle="dropdown"><i class="fa fa-share-alt"></i></button>
                                        <ul class="dropdown-menu dropdown-animation">
                                            <li class="twitter"><a target="_blank" href=""><i class="fa fa-twitter"></i></a></li>
                                            <li class="skype"><a target="_blank" href=""><i class="fa fa-skype"></i></a></li>
                                            <li class="linkedin"><a target="_blank" href=""><i class="fa fa-linkedin"></i></a></li>
                                            <li class="googleplus"><a target="_blank" href=""><i class="fa fa-google-plus"></i></a></li>
                                            <li class="youtube"><a target="_blank" href=""><i class="fa fa-youtube-play"></i></a></li>
                                            <li class="flickr"><a target="_blank" href=""><i class="fa fa-flickr"></i></a></li>
                                            <li class="facebook"><a target="_blank" href=""><i class="fa fa-facebook"></i></a></li>
                                            <li class="pinterest"><a target="_blank" href=""><i class="fa fa-pinterest"></i></a></li>
                                        </ul>
                                    </div>
                                </div>
                            </div>
                            <!-- header-top-first end -->

                        </div>
                        <div class="col-xs-10 col-sm-6">

                            <!-- header-top-second start -->
                            <!-- ================ -->
                            <div id="header-top-second"  class="clearfix">
                                <!-- header top dropdowns start -->
                                <!-- ================ -->
                                <?php if(@$_SESSION['loginFlag']):?>
                                    <div class="header-top-dropdown">
                                        <div  class="btn-group dropdown">
                                            <button type="button" class="btn dropdown-toggle" data-toggle="dropdown"><i class="fa fa-user"></i><i><?php echo $_SESSION['username'];?></i></button>
                                            <ul  class="dropdown-menu dropdown-menu-right dropdown-animation">
                                                <a href="doAction.php?act=userOut" class="btn btn-danger btn-sm">正常退出</a>
                                                <span>或</span>
                                                <a href="page-404.html" class="btn btn-success btn-sm">修改密码</a>
                                            </ul>
                                        </div>
                                        <div class="btn-group dropdown">
                                            <button type="button" class="btn dropdown-toggle" data-toggle="dropdown"><i class="fa fa-shopping-cart"></i> Cart</button>
                                            <ul class="dropdown-menu dropdown-menu-right dropdown-animation cart">
                                                <li>
                                                    <table class="table table-hover">
                                                        <thead>
                                                        <tr>
                                                            <th class="quantity">数量</th>
                                                            <th class="product">商品描述</th>
                                                            <th class="amount">商品价格</th>
                                                        </tr>
                                                        </thead>
                                                        <?php
                                                        $sql = "select c.num, p.pName, p.iPrice from imooc_pro p RIGHT JOIN shop_cart c ON p.id=c.productid WHERE c.userid={$userid}";
                                                        $rows= fetchAll($sql);
                                                        //var_dump($rows);
                                                        if ($rows && is_array($rows)):
                                                            foreach ($rows as $cartsimple):
                                                                ?>
                                                                <tbody>
                                                                <tr>
                                                                    <td class="quantity"><?php echo $cartsimple['num'];?></td>
                                                                    <td class="product"><a href="shop-product.html"><?php echo $cartsimple['pName'];?></a></td>
                                                                    <td class="amount"><?php echo $cartsimple['iPrice'];?></td>
                                                                </tr>
                                                                </tbody>
                                                                <?php
                                                            endforeach;
                                                        endif;
                                                        ?>
                                                    </table>
                                                    <div class="panel-body text-right">
                                                        <a href="shop_cart.php" class="btn btn-group btn-default btn-sm">购物车详情</a>
                                                        <a href="shop_checkout.php" class="btn btn-group btn-default btn-sm">提交订单</a>
                                                    </div>
                                                </li>
                                            </ul>
                                        </div>
                                    </div>

                                <?php else:?>

                                    <div  class="header-top-dropdown">
                                        <div  class="btn-group dropdown">
                                            <button type="button" class="btn dropdown-toggle" data-toggle="dropdown"><i class="fa fa-user"></i>登录</button>
                                            <ul  class="dropdown-menu dropdown-menu-right dropdown-animation">
                                                <li >
                                                    <form class="login-form" method="post" action="doAction.php?act=login">
                                                        <div class="form-group has-feedback">
                                                            <label class="control-label">用户名</label>
                                                            <input type="text" class="form-control" placeholder="注册时填写的邮箱" name="username">
                                                            <i class="fa fa-user form-control-feedback"></i>
                                                        </div>
                                                        <div class="form-group has-feedback">
                                                            <label class="control-label">密码</label>
                                                            <input type="password" class="form-control" placeholder="" name="password">
                                                            <i class="fa fa-lock form-control-feedback"></i>
                                                        </div>
                                                        <button type="submit" class="btn btn-group btn-dark btn-sm">登录</button>
                                                        <span>或</span>
                                                        <a href="zc.php" class="btn btn-success btn-sm">注册</a>
                                                        <ul>
                                                            <li><a href="page-404.html">忘记密码了？</a></li>
                                                        </ul>
                                                        <div class="divider"></div>
                                                        <span class="text-center">其他登录方式</span>
                                                        <ul class="social-links clearfix">
                                                            <li class="facebook"><a target="_blank" href=""><i class="fa fa-qq"></i></a></li>
                                                            <li class="twitter"><a target="_blank" href=""><i class="fa fa-weibo"></i></a></li>
                                                            <li class="googleplus"><a target="_blank" href=""><i class="fa fa-wechat"></i></a></li>
                                                        </ul>
                                                    </form>
                                                </li>
                                            </ul>
                                        </div>
                                    </div>
                                <?php endif;?>
                                <!--  header top dropdowns end -->

                            </div>
                            <!-- header-top-second end -->

                        </div>
                    </div>
                </div>
            </div>
            <!-- header-top end -->

            <!-- header start (remove fixed class from header in order to disable fixed navigation mode) -->
            <!-- ================ -->
            <header class="header fixed clearfix">
                <div class="container">
                    <div class="row">
                        <div class="col-md-3">

                            <!-- header-left start -->
                            <!-- ================ -->
                            <div class="header-left clearfix">

                                <!-- logo -->
                                <div class="logo">
                                    <a href="index.html"><img id="logo" src="images/logo_red.png" alt="iDea"></a>
                                </div>

                                <!-- name-and-slogan -->
                                <div class="site-slogan">
                                    欢迎访问我的主页！
                                </div>

                            </div>
                            <!-- header-left end -->

                        </div>
                        <div class="col-md-9">

                            <!-- header-right start -->
                            <!-- ================ -->
                            <div class="header-right clearfix">

                                <!-- main-navigation start -->
                                <!-- ================ -->
                                <div class="main-navigation animated">

                                    <!-- navbar start -->
                                    <!-- ================ -->
                                    <nav class="navbar navbar-default" role="navigation">
                                        <div class="container-fluid">

                                            <!-- Toggle get grouped for better mobile display -->
                                            <div class="navbar-header">
                                                <button type="button" class="navbar-toggle" data-toggle="collapse" data-target="#navbar-collapse-1">
                                                    <span class="sr-only">Toggle navigation</span>
                                                    <span class="icon-bar"></span>
                                                    <span class="icon-bar"></span>
                                                    <span class="icon-bar"></span>
                                                </button>
                                            </div>

                                            <!-- Collect the nav links, forms, and other content for toggling -->
                                            <div class="collapse navbar-collapse" id="navbar-collapse-1">
                                                <ul class="nav navbar-nav navbar-right">
                                                    <li class="dropdown active">
                                                        <a href="index.html" class="dropdown-toggle" data-toggle="dropdown">主页</a>
                                                        <ul class="dropdown-menu">
                                                            <li class="active"><a href="index.html">主页</a></li>
                                                            <li><a href="">Home - 2</a></li>
                                                            <li><a href="">Home - 3</a></li>
                                                            <li><a href="">Home - 4</a></li>
                                                            <li><a href="">Home - 5</a></li>
                                                            <li><a href="">Home - 8</a></li>
                                                            <li><a href="">Home - 6</a></li>
                                                            <li><a href="">Home - 7</a></li>
                                                        </ul>
                                                    </li>
                                                    <!-- mega-menu start -->
                                                    <li class="dropdown mega-menu">
                                                        <a href="" class="dropdown-toggle" data-toggle="dropdown">特殊页面</a>
                                                        <ul class="dropdown-menu">
                                                            <li>
                                                                <div class="row">
                                                                    <div class="col-lg-4 col-md-3 hidden-sm">
                                                                        <h4>文采程序员</h4>
                                                                        <p>请取之于蓝而青于蓝，冰水为之而寒于水</p>
                                                                        <img src="images/section-image-3.jpg" alt="iDea">
                                                                    </div>
                                                                    <div class="col-lg-8 col-md-9">
                                                                        <h4>我的文章</h4>
                                                                        <div class="row">
                                                                            <div class="col-sm-4">
                                                                                <div class="divider"></div>
                                                                                <ul class="menu">
                                                                                    <li><a href="blog.html"><i class="icon-right-open"></i>博文</a></li>
                                                                                    <li><a href=""><i class="icon-right-open"></i>About Us 2</a></li>
                                                                                </ul>
                                                                            </div>
                                                                            <div class="col-sm-4">
                                                                                <div class="divider"></div>
                                                                                <ul class="menu">
                                                                                    <li><a href="page-404.html"><i class="icon-right-open"></i>404页面</a></li>
                                                                                    <li><a href=""><i class="icon-right-open"></i>Contact 2</a></li>
                                                                                </ul>
                                                                            </div>
                                                                            <div class="col-sm-4">
                                                                                <div class="divider"></div>
                                                                                <ul class="menu">
                                                                                    <li><a href="page-coming-soon.html"><i class="icon-right-open"></i>即将到来页面</a></li>
                                                                                    <li><a href=""><i class="icon-right-open"></i>Contact</a></li>
                                                                                </ul>
                                                                            </div>
                                                                        </div>
                                                                    </div>
                                                                </div>
                                                            </li>
                                                        </ul>
                                                    </li>
                                                    <!-- mega-menu end -->
                                                    <li class="dropdown active">
                                                        <a href="blog.html" class="dropdown-toggle" data-toggle="dropdown">我的文章</a>
                                                        <ul class="dropdown-menu">
                                                            <li class="active"><a href="index.html">主页</a></li>
                                                            <li><a href="">Home - 2</a></li>
                                                            <li><a href="">Home - 3</a></li>
                                                            <li><a href="">Home - 4</a></li>
                                                            <li><a href="">Home - 5</a></li>
                                                            <li><a href="">Home - 8</a></li>
                                                            <li><a href="">Home - 6</a></li>
                                                            <li><a href="">Home - 7</a></li>
                                                        </ul>
                                                    </li>
                                                    <li class="dropdown active">
                                                        <a href="page-coming-soon.html" class="dropdown-toggle" data-toggle="dropdown">电影</a>
                                                        <ul class="dropdown-menu">
                                                            <li class="active"><a href="index.html">主页</a></li>
                                                            <li><a href="">Home - 2</a></li>
                                                            <li><a href="">Home - 3</a></li>
                                                            <li><a href="">Home - 4</a></li>
                                                            <li><a href="">Home - 5</a></li>
                                                            <li><a href="">Home - 8</a></li>
                                                            <li><a href="">Home - 6</a></li>
                                                            <li><a href="">Home - 7</a></li>
                                                        </ul>
                                                    </li>
                                                    <!-- mega-menu end -->
                                                    <li class="dropdown active">
                                                        <a href="music.html" class="dropdown-toggle" data-toggle="dropdown">音乐</a>
                                                        <ul class="dropdown-menu">
                                                            <li class="active"><a href="index.html">主页</a></li>
                                                            <li><a href="">Home - 2</a></li>
                                                            <li><a href="">Home - 3</a></li>
                                                            <li><a href="">Home - 4</a></li>
                                                            <li><a href="">Home - 5</a></li>
                                                            <li><a href="">Home - 8</a></li>
                                                            <li><a href="">Home - 6</a></li>
                                                            <li><a href="">Home - 7</a></li>
                                                        </ul>
                                                    </li>
                                                    <li class="dropdown active">
                                                        <a href="page-contact.html" class="dropdown-toggle" data-toggle="dropdown">联系我</a>
                                                        <ul class="dropdown-menu">
                                                            <li class="active"><a href="index.html">主页</a></li>
                                                            <li><a href="">Home - 2</a></li>
                                                            <li><a href="">Home - 3</a></li>
                                                            <li><a href="">Home - 4</a></li>
                                                            <li><a href="">Home - 5</a></li>
                                                            <li><a href="">Home - 8</a></li>
                                                            <li><a href="">Home - 6</a></li>
                                                            <li><a href="">Home - 7</a></li>
                                                        </ul>
                                                    </li>
                                                </ul>
                                            </div>

                                        </div>
                                    </nav>
                                    <!-- navbar end -->

                                </div>
                                <!-- main-navigation end -->

                            </div>
                            <!-- header-right end -->

                        </div>
                    </div>
                </div>
            </header>
            <!-- header end -->

            <!-- page-intro start-->
            <!-- ================ -->
            <div class="page-intro">
                <div class="container">
                    <div class="row">
                        <div class="col-md-12">
                            <ol class="breadcrumb">
                                <li><i class="fa fa-home pr-10"></i><a href="index.html">主页</a></li>
                                <li class="active">大大网上商城</li>
                            </ol>
                        </div>
                    </div>
                </div>
            </div>
            <!-- page-intro end -->

			<!-- main-container start -->
			<!-- ================ -->
			<section class="main-container">
                    <div class="container">
                        <div class="row">

                            <!-- main start -->
                            <!-- ================ -->
                            <div class="main col-md-12">

                                <!-- page-title start -->
                                <!-- ================ -->
                                <h1 class="page-title margin-top-clear"><?php echo $proInfo['pName'];?></h1>
                                <!-- page-title end -->

                                <div class="row">
                                    <div class="col-md-4">
                                        <!-- Nav tabs -->
                                        <ul class="nav nav-pills white space-top" role="tablist">
                                            <li class="active"><a href="#product-images" role="tab" data-toggle="tab" title="images"><i class="fa fa-camera pr-5"></i>图片</a></li>
                                        </ul>

                                        <!-- Tab panes start-->
                                        <div class="tab-content clear-style">
                                            <div class="tab-pane active" id="product-images">
                                                <div class="owl-carousel content-slider-with-controls-bottom">
                                                    <div class="overlay-container">
                                                        <img src="../image_800/<?php echo  $proImgs[0]['albumPath'];?>" alt="">
                                                    </div>
                                                </div>
                                            </div>
                                            <div class="tab-pane" id="product-video">
                                                <div class="embed-responsive embed-responsive-16by9">
                                                    <iframe class="embed-responsive-item" src="//player.vimeo.com/video/29198414?byline=0&amp;portrait=0"></iframe>
                                                    <p><a href="http://vimeo.com/29198414">Introducing Vimeo Music Store</a> from <a href="http://vimeo.com/staff">Vimeo Staff</a> on <a href="https://vimeo.com">Vimeo</a>.</p>
                                                </div>
                                            </div>
                                        </div>
                                        <!-- Tab panes end-->
                                        <hr>
                                        <span class="price">￥<?php echo $proInfo['iPrice'];?>元</span>
                                        <div class="elements-list pull-right clearfix">
                                            <span><i class="fa fa-star text-default"></i><i class="fa fa-star text-default"></i><i class="fa fa-star text-default"></i><i class="fa fa-star text-default"></i><i class="fa fa-star"></i></span>
                                            <a href="#" class="wishlist"><i class="fa fa-heart-o pr-5"></i>喜欢</a>
                                        </div>
                                        <div class="clearfix"></div>
                                        <hr>
                                        <div class="row">
                                            <div class="col-md-12">
                                                <a href="javascript:addCart(<?php echo $proInfo['id'];?>)"><i class="fa fa-shopping-cart pr-10"></i>加入购物车</a>
                                            </div>
                                            </form>
                                        </div>
                                    </div>

                                    <!-- product side start -->
                                    <aside class="col-md-8">
                                        <div class="sidebar">
                                            <div class="side product-item vertical-divider-left">
                                                <div class="tabs-style-2">
                                                    <!-- Nav tabs -->
                                                    <ul class="nav nav-tabs" role="tablist">
                                                        <li class="active"><a href="#h2tab1" role="tab" data-toggle="tab"><i class="fa fa-file-text-o pr-5"></i>Description</a></li>
                                                        <li><a href="#h2tab2" role="tab" data-toggle="tab"><i class="fa fa-files-o pr-5"></i>Specifications</a></li>
                                                        <li><a href="#h2tab3" role="tab" data-toggle="tab"><i class="fa fa-star pr-5"></i>(3) Reviews</a></li>
                                                    </ul>
                                                    <!-- Tab panes -->
                                                    <div class="tab-content padding-top-clear padding-bottom-clear">
                                                        <div class="tab-pane fade in active" id="h2tab1">
                                                            <h4 class="title"><?php echo $proInfo['pDesc'];?></h4>
                                                        </div>
                                                        <div class="tab-pane fade" id="h2tab2">
                                                            <h4 class="space-top">Specifications</h4>
                                                            <hr>
                                                            <dl class="dl-horizontal">
                                                                <dt>Screen</dt>
                                                                <dd>4.95” 1920x1080 display</dd>
                                                                <dt>Cameras</dt>
                                                                <dd>1.3MP front facing, 8MP rear facing with Optical Image Stabilization</dd>
                                                                <dt>Dimensions</dt>
                                                                <dd>69.17 x 137.84 x 8.59 mm (130g)</dd>
                                                                <dt>Battery</dt>
                                                                <dd>2300 mAh. Talk time up to 17 hours*. Standby time up to 300 hours+. Internet use time up to 8.5 hours on Wi-Fi, up to 7 hours on LTE. Wireless Charging built-in</dd>
                                                                <dt>Audio</dt>
                                                                <dd>Built-in speaker 3.5mm stereo audio connector</dd>
                                                                <dt>Processing</dt>
                                                                <dd>CPU: Qualcomm SnapdragonTM 800, 2.26GHz processor</dd>
                                                                <dd>GPU: Adreno 330, 450MHz</dd>
                                                                <dt>Wireless</dt>
                                                                <dd>Dual-band Wi-Fi (2.4G/5G) 802.11 a/b/g/n/ac</dd>
                                                            </dl>
                                                            <hr>
                                                        </div>
                                                        <div class="tab-pane fade" id="h2tab3">
                                                            <!-- comments start -->
                                                            <div class="comments margin-clear space-top">
                                                                <!-- comment start -->
                                                                <div class="comment clearfix">
                                                                    <div class="comment-avatar">
                                                                        <img src="images/avatar.jpg" alt="avatar">
                                                                    </div>
                                                                    <div class="comment-content">
                                                                        <h3>Amazing!</h3>
                                                                        <div class="comment-meta"> <i class="fa fa-star text-default"></i> <i class="fa fa-star text-default"></i> <i class="fa fa-star text-default"></i> <i class="fa fa-star text-default"></i> <i class="fa fa-star"></i> | Today, 12:31</div>
                                                                        <div class="comment-body clearfix">
                                                                            <p>Lorem ipsum dolor sit amet, consectetur adipisicing elit, sed do eiusmod tempor incididunt ut labore et dolore magna aliqua. Ut enim ad minim veniam, quis nostrud exercitation ullamco laboris nisi ut aliquip ex ea commodo </p>
                                                                            <a href="blog-post.html" class="btn btn-gray more pull-right"><i class="fa fa-reply"></i> Reply</a>
                                                                        </div>
                                                                    </div>

                                                                </div>
                                                                <!-- comment end -->

                                                                <!-- comment start -->
                                                                <div class="comment clearfix">
                                                                    <div class="comment-avatar">
                                                                        <img src="images/avatar.jpg" alt="avatar">
                                                                    </div>
                                                                    <div class="comment-content clearfix">
                                                                        <h3>Works Perfect!</h3>
                                                                        <div class="comment-meta"> <i class="fa fa-star text-default"></i> <i class="fa fa-star text-default"></i> <i class="fa fa-star text-default"></i> <i class="fa fa-star text-default"></i> <i class="fa fa-star text-default"></i> | Oct 15</div>
                                                                        <div class="comment-body">
                                                                            <p>Lorem ipsum dolor sit amet, consectetur adipisicing elit, sed do eiusmod tempor incididunt ut labore et dolore magna aliqua. Ut enim ad minim veniam, quis nostrud exercitation ullamco laboris nisi ut aliquip ex ea commodo </p>
                                                                            <a href="blog-post.html" class="btn btn-gray more pull-right"><i class="fa fa-reply"></i> Reply</a>
                                                                        </div>
                                                                    </div>
                                                                </div>
                                                                <!-- comment end -->

                                                                <!-- comment start -->
                                                                <div class="comment clearfix">
                                                                    <div class="comment-avatar">
                                                                        <img src="images/avatar.jpg" alt="avatar">
                                                                    </div>
                                                                    <div class="comment-content clearfix">
                                                                        <h3>Worth to Buy</h3>
                                                                        <div class="comment-meta"> <i class="fa fa-star text-default"></i> <i class="fa fa-star text-default"></i> <i class="fa fa-star text-default"></i> <i class="fa fa-star"></i> <i class="fa fa-star"></i> | Sep 25</div>
                                                                        <div class="comment-body">
                                                                            <p>Lorem ipsum dolor sit amet, consectetur adipisicing elit, sed do eiusmod tempor incididunt ut labore et dolore magna aliqua. Ut enim ad minim veniam, quis nostrud exercitation ullamco laboris nisi ut aliquip ex ea commodo </p>
                                                                            <a href="blog-post.html" class="btn btn-gray more pull-right"><i class="fa fa-reply"></i> Reply</a>
                                                                        </div>
                                                                    </div>
                                                                </div>
                                                                <!-- comment end -->

                                                            </div>
                                                            <!-- comments end -->

                                                            <!-- comments form start -->
                                                            <div class="comments-form">
                                                                <h2 class="title">Add your Review</h2>
                                                                <form role="form" id="comment-form">
                                                                    <div class="form-group has-feedback">
                                                                        <label for="name4">Name</label>
                                                                        <input type="text" class="form-control" id="name4" placeholder="" name="name4" required>
                                                                        <i class="fa fa-user form-control-feedback"></i>
                                                                    </div>
                                                                    <div class="form-group has-feedback">
                                                                        <label for="subject4">Subject</label>
                                                                        <input type="text" class="form-control" id="subject4" placeholder="" name="subject4" required>
                                                                        <i class="fa fa-pencil form-control-feedback"></i>
                                                                    </div>
                                                                    <div class="form-group">
                                                                        <label>Rating</label>
                                                                        <select class="form-control" id="review">
                                                                            <option value="five">5</option>
                                                                            <option value="four">4</option>
                                                                            <option value="three">3</option>
                                                                            <option value="two">2</option>
                                                                            <option value="one">1</option>
                                                                        </select>
                                                                    </div>
                                                                    <div class="form-group has-feedback">
                                                                        <label for="message4">Message</label>
                                                                        <textarea class="form-control" rows="8" id="message4" placeholder="" name="message4" required></textarea>
                                                                        <i class="fa fa-envelope-o form-control-feedback"></i>
                                                                    </div>
                                                                    <input type="submit" value="Submit" class="btn btn-default">
                                                                </form>
                                                            </div>
                                                            <!-- comments form end -->
                                                        </div>
                                                    </div>
                                                </div>
                                            </div>
                                        </div>
                                    </aside>
                                    <!-- product side end -->
                                </div>

                            </div>
                            <!-- main end -->

                        </div>
                    </div>
			</section>
			<!-- main-container end -->



		<!-- JavaScript files placed at the end of the document so the pages load faster
================================================== -->
		<!-- Jquery and Bootstap core js files -->
            <script type="text/javascript">
                function addCart(productid) {
                    var url="addCart.php";
                    var num =1;
                    var data={"productid":productid,"num": 1};
                    var success = function (response) {
                        if(response.errno == 0){
                            alert('加入购物车成功')
                        }else {
                            alert('加入购物车失败,请登录添加')
                        }

                    }
                    $.post(url,data,success,"json");

                    //alert(productid);
                }
            </script>
		<script type="text/javascript" src="plugins/jquery.min.js"></script>
		<script type="text/javascript" src="bootstrap/js/bootstrap.min.js"></script>

		<!-- Modernizr javascript -->
		<script type="text/javascript" src="plugins/modernizr.js"></script>

		<!-- Isotope javascript -->
		<script type="text/javascript" src="plugins/isotope/isotope.pkgd.min.js"></script>

		<!-- Owl carousel javascript -->
		<script type="text/javascript" src="plugins/owl-carousel/owl.carousel.js"></script>

		<!-- Magnific Popup javascript -->
		<script type="text/javascript" src="plugins/magnific-popup/jquery.magnific-popup.min.js"></script>

		<!-- Appear javascript -->
		<script type="text/javascript" src="plugins/jquery.appear.js"></script>

		<!-- Sharrre javascript -->
		<script type="text/javascript" src="plugins/jquery.sharrre.js"></script>

		<!-- Count To javascript -->
		<script type="text/javascript" src="plugins/jquery.countTo.js"></script>

		<!-- Parallax javascript -->
		<script src="plugins/jquery.parallax-1.1.3.js"></script>

		<!-- Contact form -->
		<script src="plugins/jquery.validate.js"></script>

		<!-- Initialization of Plugins -->
		<script type="text/javascript" src="js/template.js"></script>

		<!-- Custom Scripts -->
		<script type="text/javascript" src="js/custom.js"></script>

	</body>
</html>
